{% extends "master.html" %}
{% from "_formhelpers.html" import render_field_in_row %}

{% block title %}New Host ACL IP{% endblock %}
{%block tag %}home{% endblock %}

{% block content %}
<h2>Add host ACL IP</h2>

<p>
  Back to <a href="{{ url_for('host_view', host_id=host.id) }}">
    {{ host.name }}</a>
</p>

{%- if config['MASTER_RSYNC_ACL'] -%}
<p>
  These host DNS names and/or IP addresses will be allowed to rsync from the
  master rsync/ftp servers. List here all the machines that you use for
  pulling.
</p>

<form action="{{ url_for('host_acl_ip_new', host_id=host.id) }}" method="POST">
  <table>
    {{ render_field_in_row(form.ip) }}
  </table>
  <p class="buttons indent">
    <input type="submit" class="submit positive button" value="Create">
    <a href="{{ url_for('host_view', host_id=host.id) }}">
      <input type="button" value="Cancel" class="button">
    </a>
    {{ form.csrf_token }}
  </p>
</form>
{%- endif -%}{# MASTER_RSYNC_ACL ##}

{% endblock %}
